The present invention is generally related to connecting a plurality of peripherals to a bus in a computer. More particularly, the present invention is related to providing a peripheral with control of a disk controller in a computer through a bus.
Servers and other devices providing services for a large number of clients generally need to store large amounts of data that may be accessed by clients. Often, storage space provided with servers and other similar devices (e.g., mainframes, workstations and the like) becomes inadequate. Accordingly, storage devices have been developed that can be connected to servers and other similar devices.
One such storage device includes a redundant array of inexpensive disks (RAID). A RAID typically includes one or more small computer system interface (SCSI) controllers for controlling input/output (I/O) operations for each of the RAID""s drives and other peripherals connected to the server""s bus. Conventionally, a server also includes at least one SCSI controller, for example, connected to the server motherboard, for controlling I/O operations for peripherals connected to the bus.
In order to minimize costs, ideally the RAID should utilize the SCSI controller located in the server, rather than providing SCSI controllers with the RAID. However, if the RAID were to utilize the SCSI controller in the server, the I/O processor for the RAID and the central processing unit (CPU) in the server would compete for control of the SCSI controller. For example, the CPU may attempt to communicate with the SCSI controller in the server to handle an I/O operation for a peripheral connected to the bus. The RAID may also attempt to communicate with the SCSI controller in the server to handle an I/O operation for the RAID. This may result in data collisions, data loss and/or system failure.
The present invention facilitates use of a preexisting controller in a host for a peripheral device connected to the host.
In one respect the present invention includes a circuit in a computer system. The computer system includes a host and a peripheral device connected to the host, and the host includes a device controller to control data operations for the peripheral device. The integrated circuit is operable to connect the device controller to the peripheral device via a bus in the host, such that the peripheral device is provided with sole access to the device controller.
The circuit includes a logic circuit operable to detect when the peripheral device is granted master access to the bus based on a first signal and to detect when the bus is idle based on a plurality of second signals. The logic circuit is further operable to connect the device controller to the bus when the peripheral device is granted master access to the bus and when the bus idle. The logic circuit is further operable to disconnect the device controller from the bus when master access is not granted to the peripheral device and/or when the bus is not idle.
The circuit is further operable to function in two modes. In a first mode (e.g., a straight mode) the peripheral device is provided with sole access to the device controller. In a second mode (e.g., a standard mode), other devices may gain access to the device controller.
In another respect the present invention includes a method of providing a peripheral device access to a device controller in a host. The method includes steps of (1) determining whether said peripheral device is granted master access to a bus in said host; (2) determining whether said bus is idle; and (3) providing said peripheral device with sole access to said device controller in response to said peripheral device being granted master access to said bus and said bus being idle.